package com.hznc.wcs.entity.modbusconfig;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;
import java.lang.Double;
import java.math.BigDecimal;
import jakarta.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;
import com.diboot.core.util.D;
import com.diboot.core.entity.BaseModel;
import com.diboot.core.entity.BaseEntity;
import com.diboot.core.binding.query.BindQuery;
import com.diboot.core.binding.query.Comparison;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;

import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
* ModbusSalve配置 Entity 定义
* @author MyName
* @version 1.0
* @date 2024-11-29
* Copyright © MyCorp
*/
@TableName("mdl_modbus_slave_config")
@Getter @Setter @Accessors(chain = true)
public class ModbusSlaveConfig extends BaseModel {
    private static final long serialVersionUID = 1122595922519163954L;
     /**
     * 编码
     */
     @NotNull(message = "编码不能为空")
     @Length(max=100, message="编码长度应小于100")
     @BindQuery(comparison = Comparison.LIKE)
     @TableField()
     private String code;

     /**
     * 名称
     */
     @Length(max=100, message="名称长度应小于100")
     @BindQuery(comparison = Comparison.LIKE)
     @TableField()
     private String name;

     /**
     * 主机
     */
     @NotNull(message = "主机不能为空")
     @Length(max=100, message="主机长度应小于100")
     @BindQuery(comparison = Comparison.LIKE)
     @TableField(value = "`host`")
     private String host;

     /**
     * 端口
     */
     @NotNull(message = "端口不能为空")
     @Length(max=100, message="端口长度应小于100")
     @BindQuery(comparison = Comparison.LIKE)
     @TableField(value = "`port`")
     private Integer port;

     /**
     * 协议
     */
     @TableField()
     private String protocol;


}